export default {
  computed: {
    // 模块名称
    moduleName() {
      return this.option.moduleName
    },
    isShowModuleName() {
      return this.option.isShowModuleName
    },
    spacing() {
      return this.px2rem(this.option.spacing || 0)
    },
    link() {
      return this.option.link
    },
    imgBg() {
      return this.option.imgBg || 'https://bjttsx-yanshi.oss-cn-beijing.aliyuncs.com/4146cde6-8f9b-4580-a154-f410e2c3fd2a/22/11/07/221107995cbde370d841ea8e78a15b526de261.png'
    },
    showMore() {
      return this.option.showMore
    },
    moreLink() {
      return this.option.moreLink
    }
  },
  methods: {
    toMore(path) {
      if (this.moreLink.link) {
        if (this.moreLink.link.startsWith('http')) {
          window.location.href = this.moreLink.link
        } else {
          this.$router.push({ path: this.moreLink.link })
        }
      }
    }
  }
}
